# -*- coding: utf-8 -*-
from flask import Flask,request,abort,Response,Blueprint
app = Flask(__name__)

# @app.route('/',methods=['POST','GET'])
# def f1():
#     return "这是第一个路由"

@app.route('/',methods=['POST','GET'])
def f1():
    js = request.get_json()
    name = js.get("name")
    age = js.get("age")
    return "我的名字是%s,今年%d岁" % (name,age)


# from flask import Flask
# app = Flask(__name__)

# @app.route('/')
# def hello_world():
#     return 'Hello, World!'

if __name__ == '__main__':
    app.run(port=8888,debug = True)
